<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
		"http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
	<title>Editor Test</title>

	<style type="text/css">
		@import "../../../dojo/resources/dojo.css";
		@import "../css/dijitTests.css";
	</style>

	<!-- required: a default dijit theme: -->
	<link id="themeStyles" rel="stylesheet" href="../../../dijit/themes/claro/claro.css">

	<!-- required: dojo.js -->
	<script type="text/javascript" src="../../../dojo/dojo.js"
		djConfig="parseOnLoad: true, isDebug: true"></script>

	<!-- not needed, for testing alternate themes -->
	<script type="text/javascript" src="../_testCommon.js"></script>


	<script type="text/javascript">
		dojo.require("dojo.window");
		dojo.require("dijit.dijit"); // optimize: load dijit layer
		dojo.require("dijit.Editor");
		dojo.require("dijit._editor.plugins.AlwaysShowToolbar");
		dojo.require("dijit._editor.plugins.FontChoice");  // 'fontName','fontSize','formatBlock'
		dojo.require("dijit._editor.plugins.TextColor");
		dojo.require("dijit._editor.plugins.LinkDialog");
		if(!window.parent.dijit.robot){
			dojo.require("dijit.robot"); // test kludge, we just want the robot's cool scrollIntoView for the bold text test below and not the applet
		}else{
			doh=window.parent.doh;
		}
		dojo.require("dojo.parser");	// scan page for widgets and instantiate them
	</script>
</head>

<body class="claro">
<div>some content
<div>more contentmargin:50px;border:50px solid red; padding:50px;
<iframe src="test_Editor.html" id="iframe" style="width:100px; height:50px; overflow:hidden;">
</iframe>
<input type="button" dojoType="dijit.form.Button" onClick="var frame=dojo.byId('iframe');dojo.withGlobal(frame.contentWindow, function(){frame.contentWindow.dojo.window.scrollIntoView(frame.contentWindow.dijit.byId('editor1').toolbar.getChildren()[7].domNode);});alert('expected Bold, got: '+frame.contentWindow.dijit.byId('editor1').toolbar.getChildren()[7].titleNode.getAttribute('title'))">Scroll bold into view</input>
<input type="button" dojoType="dijit.form.Button" onClick="var frame=dojo.byId('iframe');doh.robot.scrollIntoView(dojo.query(dojo.isIE?'strong':'b',frame.contentWindow.dijit.byId('editor1').document.body)[0]);">Scroll bold text into view</input>
<input type="button" dojoType="dijit.form.Button" onClick="var frame=dojo.byId('iframe');dojo.withGlobal(frame.contentWindow, function(){frame.contentWindow.dojo.window.scrollIntoView(frame.contentWindow.dijit.byId('editor1').toolbar.getChildren()[8].domNode);});alert('expected Italic, got: '+frame.contentWindow.dijit.byId('editor1').toolbar.getChildren()[8].titleNode.getAttribute('title'))">Scroll italics into view</input>
</div>
</div>
</body>
</html>
